package hu.uszeged.inf.wlab.stunner.database.dtos;

import java.io.Serializable;

import org.codehaus.jackson.annotate.JsonIgnore;

/**
 * DTO to store battery information.
 * 
 * @author szelezsant
 */
public class BatteryInfoDTO implements Serializable {

	/**
	 * Generated id.
	 */
	private static final long serialVersionUID = -138245645286411780L;

	/** The identifier. */
	private long identifier;
	/** The remaining percentage. */
	private int percentage;
	/** The charging state according to the values stored in {@link android.os.BatteryManager BatteryManager}. */
	private int chargingState;
	/** The health according to the values stored in {@link android.os.BatteryManager BatteryManager}. */
	private int health;
	/** The temperature value. */
	private Integer temperature;
	/** The voltage. */
	private Integer voltage;

	/**
	 * @return the id
	 */
	@JsonIgnore
	public long getId() {
		return identifier;
	}

	/**
	 * @param idToSet the id to set
	 */
	@JsonIgnore
	public void setId(final long idToSet) {
		this.identifier = idToSet;
	}

	/**
	 * @return the percentage
	 */
	public int getPercentage() {
		return percentage;
	}

	/**
	 * @param percentage the percentage to set
	 */
	public void setPercentage(final int percentage) {
		this.percentage = percentage;
	}

	/**
	 * @return the chargingState
	 */
	public int getChargingState() {
		return chargingState;
	}

	/**
	 * @param chargingState the chargingState to set
	 */
	public void setChargingState(final int chargingState) {
		this.chargingState = chargingState;
	}

	/**
	 * @return the health
	 */
	public int getHealth() {
		return health;
	}

	/**
	 * @param health the health to set
	 */
	public void setHealth(final int health) {
		this.health = health;
	}

	/**
	 * @return the temperature
	 */
	public int getTemperature() {
		return temperature;
	}

	/**
	 * @param temperature the temperature to set
	 */
	public void setTemperature(final int temperature) {
		this.temperature = temperature;
	}

	/**
	 * @return the voltage
	 */
	public int getVoltage() {
		return voltage;
	}

	/**
	 * @param voltage the voltage to set
	 */
	public void setVoltage(final int voltage) {
		this.voltage = voltage;
	}

	/*
	 * (non-Javadoc)
	 * @see java.lang.Object#toString()
	 */
	@Override
	public String toString() {
		return "BatteryInfoDTO [id=" + identifier + ", percentage=" + percentage + ", chargingState=" + chargingState + ", health="
				+ health
				+ ", temperature=" + temperature + ", voltage=" + voltage + "]";
	}
}
